﻿using System.Modules.SharePoint.Constants;

namespace System.Modules.SharePoint.Contracts.DTO
{
    /// <summary>
    /// SPSiteDataQueryWithIndex
    /// </summary>
    public class SPSiteDataQueryWithIndex : SPSiteDataQueryListsSubElement
    {
        #region Properties
        /// <summary>
        /// FieldId
        /// </summary>
        public Guid FieldId { get; set; }
        /// <summary>
        /// Type
        /// </summary>
        public string Type { get; set; }
        /// <summary>
        /// Value
        /// </summary>
        public string Value { get; set; }
        #endregion

        #region Methods
        /// <summary>
        /// Overrides To String method
        /// </summary>
        /// <returns></returns>
        public override string ToString()
        {
            return string.Format(SPQueryTemplates.SP_SITE_DATA_QUERY_WITH_INDEX, FieldId, Type, Value);
        }
        #endregion
    }
}
